﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using SwenAssignment3.Classes;

namespace SwenAssignment3.ReportingModule
{
    public partial class RoomOccupancy : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack) 
            {
                GridView1.DataSource = DRHotelDBManager.retrieveRooms(roomtypeddl.SelectedValue).ToList();
                GridView1.DataBind();

            }
        }

        

        protected void roomtypeddl_SelectedIndexChanged(object sender, EventArgs e)
        {
            GridView1.DataSource = DRHotelDBManager.retrieveRooms(roomtypeddl.SelectedValue).ToList();
            GridView1.DataBind();
        }

        
     
    }
}